package io.renren.dao;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import io.renren.common.dao.BaseDao;
import io.renren.dto.repon.RepairquotationmRepon;
import io.renren.entity.RepairquotationmEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * ${comments}
 *
 * @author Sen 524227263@qq.com
 * @since 1.0.0 2024-05-28
 */
@Mapper
public interface RepairquotationmDao extends BaseDao<RepairquotationmEntity> {

    @Select("SELECT a.SYS_Created,a.RepairQuotationMOID,a.TotalAmount as Amount,a.UCML_CONTACT_FK,a.Auto_FK,b.OrgName, c.PersonName,d.AutoNo" +
            " from RepairQuotationM a " +
            "LEFT JOIN UCML_Organize b ON b.UCML_OrganizeOID=a.Org_FK " +
            "LEFT JOIN UCML_CONTACT c ON c.UCML_CONTACTOID=a.UCML_CONTACT_FK " +
            "LEFT JOIN Auto d ON d.AutoOID=a.Auto_FK " +
            "where ${ew.sqlSegment}")
    List<RepairquotationmRepon> selectListByIsCustomerConfirm(@Param("ew") QueryWrapper<RepairquotationmEntity> wrapper);
}